package com.bluefish.bltuan.dao.impl;

import java.util.List;

import org.springframework.stereotype.Repository;

import com.bluefish.bltuan.dao.OrderDao;
import com.bluefish.bltuan.module.shop.Order;
import com.bluefish.bltuan.module.shop.TuanGou;
import com.bluefish.bltuan.module.user.User;
import com.bluefish.bltuan.util.PageIndex;

@Repository
public class OrderDaoImpl extends AbstractDaoImpl<Order, Integer> implements OrderDao {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public List<Order> listByUser(User user, PageIndex pageIndex) {
		return listByProperty(pageIndex, "user", user);
	}

	public List<Order> listByTuangou(TuanGou tuanGou, PageIndex pageIndex) {
		return listByProperty(pageIndex, "tuangou", tuanGou);
	}

	
}
